package controller;

import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.springframework.stereotype.Controller;
import service.JedisClient;

/**
 * 这是redis的增删查的接口实现类
 * Created by yyl on 2017/5/23 0023.
 */
@Controller
public class testJedisClient {

    @Autowired
    private JedisClient jedisClient;



    @Test
    //redis的查询方法
    public void find() {
        String result = jedisClient.get("newname");
        System.out.print(result);
    }

//    @Test
//    //redis的添加方法
//    public String set() {
//        String result = jedisClient.set("Hellow", "你好啊");
//        return result;
//    }

//    @Test
//    //redis删除的方法
//    public void del() {
//        long result = jedisClient.del("Hellow");
//        return result;
//    }

}
